$white: #fff;
$black: #333;

body {
    background: rgb(240,240,240);
    color: #666;
}
a {
    text-decoration: none;
    color: $black;
}
.container {
    background-color: #fff;
    border-radius: 4px;
    border: 1px solid #eee;
    width: 80%;
    margin: 0 auto;
}

.nav-bar {
    background-color: $black;
    color: $white;
    line-height: 50px;
    margin: 0 -10px;
    position: relative;
    li {
        display: inline-block;
        a {
            padding: 0 25px;
            display: inline-block;
            font-size: 15px;
            color: $white;
            text-decoration: none;
        }
        ul {
            display: none;
        }
        &.active,
        &:hover {
            background-color: #000;
        }
    }
    &::before {
        content: "";
        position: absolute;
        top: -10px;
        right: 0;
        width: 0;
        height: 0;
        border-width: 10px 0 0 10px;
        border-style: solid;
        border-color: transparent transparent transparent #ccc;
    }
    &::after {
        content: "";
        position: absolute;
        top: -10px;
        left: 0;
        width: 0;
        height: 0;
        border-width: 0 0 10px 10px;
        border-style: solid;
        border-color: transparent transparent #ccc transparent;
    }
}

.panel {
    .panel-header {
        line-height: 50px;
        font-size: 20px;
        padding: 0 10px;
        .tab-header {
            float: right;
            margin: 0;
        }
        .more,
        .tip {
            margin-left: 10px;
            float: right;
            color: #999;
            font-size: 14px;
        }
    }
}

.video-item {
    margin: 10px;
    display: inline-block;
    width: 200px;
    .title {
        line-height: 30px;
        margin-top: 10px;
    }
    &:hover {
        .thumb {
            .play-icon {
                display: block;
            }
        }
    }
}

.screen-box {
    .screen-grid {
        max-height: 120px;
        overflow-y: hidden;
    }
    .screen-line {
        display: flex;
        border-bottom: 1px dashed #dedede;
        line-height: 40px;
        .line-title {
            flex: 0 0 auto;
            width: 80px;
            text-align: center;
        }
        .line-more {
            flex: 0 0 auto;
            width: 60px;
            cursor: pointer;
        }
        .line-body {
            flex: 1;
            max-height: 40px;
            overflow-y: hidden;
            a {
                line-height: 30px;
                padding: 0 5px;
                margin: 0 5px;
                display: inline-block;
                &.active {
                    background-color: $black;
                    color: $white;
                }
            }
        }
        &.line-open {
            .line-body {
                max-height: initial;
            }
            .line-more {
                display: none;
            }
        }
    }
    .screen-more {
        border-top: 1px solid #dedede;
        text-align: center;
        a {
            border: 1px solid #dedede;
            padding: 0 20px;
        }
    }
    &.screen-open {
        .screen-grid {
            max-height: initial;
        }
        .screen-more {
            display: none;
        }
    }
}
.tab-header {
    text-align: center;
    font-size: 14px;
    margin: 20px 0;
    a {
        margin-left: 10px;
        display: inline-block;
        position: relative;
        height: 28px;
        line-height: 25px;
        padding: 0 15px;
        border-radius: 4px;
        border: 1px solid #eee;
        &.active {
            background-color: $black;
            color: $white;
            &::before {
                content: " ";
                width: 10px;
                height: 10px;
                transform: rotate(-45deg);
                position: absolute;
                bottom: -5px;
                right: 50%;
                margin-right: -5px;
                background-color: #333;
            }
        }
    }
}

.video-item,
.info-header {
    .thumb {
        height: 300px;
        position: relative;
        background-color: rgb(245,245,245);
        img {
            width: 100%;
            height: 100%;
        }
        .play-icon {
            display: none;
            position: absolute;
            top: 0;
            z-index: 1;
            width: 100%;
            height: 100%;
            background: rgba(0,0,0,0.1);
            &::after {
                font-family: "Font Awesome 5 Free";
                font-weight: 900;
                font-style: normal;
                content: "\f144";
                font-size: 50px;
                color: $black;
                position: absolute;
                left: 75px;
                top: 125px;
            }
        }
        .tag {
            display: block;
            width: 100%;
            position: absolute;
            z-index: 2;
            bottom: 0;
            left: 0;
            padding: 5px 10px;
            text-align: right;
            font-size: 12px;
            overflow: hidden;
            text-overflow: ellipsis;
            white-space: nowrap;
            background-repeat: no-repeat;
            background-image: linear-gradient(transparent,rgba(0,0,0,.5));
            color: #FFFFFF;
        }
    }
}

.info-header {
    display: grid;
    grid-template-columns: 200px 1fr;
    gap: 10px;
}
.info-header .header-detail,
.play-box .play-detail {
    color: $black;
    .title {
        line-height: 40px;
        font-weight: 700;
    }
    .tag {
        color: #666;
    }
    p {
        margin-bottom: 10px;
    }
    .split-line {
        display: inline-block;
        margin-left: 12px;
        margin-right: 12px;
        width: 1px;
        height: 14px;
        vertical-align: -2px;
        background-color: #eee;
    }
}
.play-action {
    float: right;
}
.play-item {
    display: inline-block;
    position: relative;
    padding: 5px 10px;
    text-align: center;
    border: 1px solid #eee;
    border-radius: 5px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    margin: 0 10px 10px 0;
}
.btn {
    border-radius: 5px;
    background-color: #f5f5f5;
    &.btn-primary {
        border: 1px solid $black;
        background-color: $black;
        color: $white;
    }
}

footer {
    margin-top: 30px;
    padding: 30px 0;
    border-top: 1px solid #ddd;
    color: $white;
    background: $black;
    .copyright {
        text-align: center;
    }
    a {
        color: $white;
        text-decoration: none;
    }
}

@media (max-width: 1200px){
    .container {
        width: 95%;
    }
}

@media (max-width: 768px){
    .container {
        width: 100%;
        .row {
            margin: 0;
        }
    }
    .nav-bar {
        margin: 0;
        &::before,
        &::after {
            display: none;
        }
    }
    .video-item {
        width: 150px;
        .thumb {
            height: 200px;
            .play-icon {
                &::after {
                    left: 50px;
                    top: 75px;
                }
            }
        }
    }
    .info-header {
        display: block;
    }
    .play-action {
        float: none;
        .btn {
            padding: 0 10px;
        }
    }
}